import QtQuick 2.1
import QtQuick.Controls 1.0
import QtQuick.Window 2.0
import QtQuick.Dialogs 1.0
import QtQuick.Controls.Styles 1.0



Rectangle {
    id: rightPane
    color: "steelblue"

    property int editIndex

    Loader {
        id: paneLoader

        anchors.fill: parent
        anchors.topMargin: 0
        anchors.margins: 6

        onLoaded: {
            paneLoader.item.editIndex = editIndex;
        }
    }

    states: [
        State {
            name: ""
            PropertyChanges {
                target: rightPane
                visible: false
            }
        },


        State {
            name: "Skills"
            PropertyChanges {
                target: paneLoader
                source: "SkillEditPane.qml"
            }
            PropertyChanges {
                target: rightPane
                visible: true
            }
        },

        State {
            name: "Character"
            PropertyChanges {
                target: paneLoader
                source: "CharacterEditPane.qml"
            }
            PropertyChanges {
                target: rightPane
                visible: true
            }
        }
    ]
}
